<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>函数调用</title>
	</head>
	<body>
		<p id='demo'></p>
		<script>
			var demo=document.getElementById('demo');
	      function findMax(){
	   	
		sum=arguments[0];
		for(var i=0;i<arguments.length;i++){
					if(sum<arguments[i+1]){
						sum=arguments[i+1];
					}
			}
			return sum;
		}
	   
	   console.log(findMax(4,5));
	   console.log(findMax(4,5,6,7));
	   demo.innerHTML =findMax(96, 23, 50, 177, 47, 38,63,32,11);
		</script>
	</body>
</html>
